//秒杀

    settime()

    setInterval(settime, 1000);

    function settime() {
        let time = new Date().getTime();
        let times = new Date('2020-12-31 00:00:00').getTime();
        let ntime = times - time;
        let num1 =document.getElementById('num1')
        let num2 =document.getElementById('num2')
        let num3 =document.getElementById('num3')
        console.log(ntime);
    
        let hour = Math.floor(ntime / 1000 / 60 / 60);
        console.log(hour);
    
        let minute = Math.floor(ntime / 1000 / 60 % 60)
        console.log(minute);
    
        let second = Math.floor(ntime / 1000 % 60)
        console.log(second);

        num1.innerHTML=`${hour}`;
        num2.innerHTML=`${minute}`;
        num3.innerHTML=`${second}`;
    }    



// 主要内容选项卡

function tabbox(obj,conlist){
    $(obj).mouseenter(function(){ 
        $(this).addClass('active').siblings().removeClass('active')
        let index =$(this).index()
        $(conlist).eq(index-1).addClass('show').siblings().removeClass('show')
        console.log($(this))
    })  
}

tabbox('#card .head a','#card .min_box');
tabbox('#card2 .head a','#card2 .min_box');
tabbox('#card3 .head a','#card3 .min_box');
tabbox('#card4 .head a','#card4 .min_box');
tabbox('.lady .right_pic li a','.lady .right_pic div')








// 轮播
jQuery(function ($) {

    $('#demo3').slideBox({


        duration: 0.3,//滚动持续时间，单位：秒

        easing: 'linear',//swing,linear//滚动特效

        delay: 1,//滚动延迟时间，单位：秒

        hideClickBar: false,//不自动隐藏点选按键



    });


<<<<<<< HEAD
});

// 滑动出现搜索框


function scroll(box){
    $(window).scroll(function(){
        if($(window).scrollTop()>500){
            $(box).show()
        }else{
            $(box).hide()
        }
    })
}

scroll('#searchbox');
scroll('.code')
=======
});
>>>>>>> edb33377eaff027e20a1e6d92339f4fb01e8ce17
